<div ng-controller="DistributorCtrl" ng-init="clearingorderAction()">
    <ul class="sui-breadcrumb">
        <li>{{'结算'| translate}}</li>
        <li>{{'List'|translate}}</a>
        </li>
        <span class="sui-form sui-form pull-right">
            <input type="text" placeholder="{{'Orderid'|translate}}" ng-model="order_id">
            <input placeholder="{{'start time'|translate}}" datetimepicker ng-model="start_time">
            <input placeholder="{{'end time'|translate}}" datetimepicker min-date="{{start_time}}" ng-model="end_time">
            <button class="sui-btn btn-primary" ng-click="getClearingOrderList()">{{'search'|translate}}</button>
        </span>
    </ul>
    <fxclearing-tab ng-model="chosedClearingStatus" click-tab="getClearingOrderList()"></fxclearing-tab>
    <table class="sui-table table-bordered">
        <thead>
            <tr>
                <th>{{'编号'|translate}}</th>
                <th>{{'代理商信息'|translate}}</th>
                <th>{{'提现金额'|translate}}</th>
                <th>{{'提现时间'|translate}}</th>
                <th>{{'状态'|translate}}</th>
            </tr>
        </thead>
        <tbody>
            <tr ng-repeat="list in clearing_list" ng-show="clearing_list.length>0">
                <td>{{list.clearing_id}}</td>
                <td>
                    <wxinfo ng-model="list.user_id" stye="1"></wxinfo>
                </td>
                <td>{{list.withdrawal_amount}}</td>
                <td>{{list.withdrawal_time | ddtt}}</td>
                <td>
                    <span ng-show="list.status ==1" class="sui-text-info">
                        <button class="sui-btn btn-success" ng-click="shOrder(list.clearing_id)">待审核</button>
                        <button class="sui-btn btn-success" ng-click="zuofeiOrder(list.clearing_id)">作废</button>
                    </span>
                    <span ng-show="list.status ==2" class="sui-text-success">
                        <button class="sui-btn btn-success" ng-click="zfOrder(list.clearing_id)">待支付</button>
                        <button class="sui-btn btn-success" ng-click="sgOrder(list.clearing_id)">手工支付佣金</button>
                    </span>
                    <span ng-show="list.status ==3" class="sui-text-danger">
                        <button class="sui-btn btn-success">已支付</button>
                    </span>
                    <a href="#/distributor/clearingdetail?clearing_id={{list.clearing_id}}" class="sui-btn btn-primary">明细</a>
                </td>
            </tr>
        </tbody>
    </table>
    <!-- 分页start -->
    <pager page-no="1" page-size="pageSize" total="total_count" get-data="getClearingOrderList(pageNo)"></pager>
    <!-- 分页end -->
</div>